home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
404 Jogos
/
CLJG.iso
/
Aventura
/
FireMan.swf
/
scripts
/
frame_1179
/
PlaceObject2_1103_88
/
CLIPACTIONRECORD onClipEvent(enterFrame).as
next >
Wrap
Text File
|
2008-09-12
|
925b
|
36 lines
onClipEvent(enterFrame){
function wallizq()
{
return dx < 0 && mapa.hitTest(_X,_Y,true);
}
function wallder()
{
return dx > 0 && mapa.hitTest(_X,_Y,true);
}
_visible = this.hitTest(_root.mascara);
_X = _X - heroe.scrollspeed;
if(mover)
{
_X = _X + dx;
_Y = _Y + dy;
if(wallizq() || wallder())
{
mover = false;
borrar = true;
for(i in angulos)
{
u = !u;
shObj = {_x:_X,_y:_Y,mover:true};
shObj.dx = freeze._xscale <= 0 ? SPEED * Math.cos(angulos[i]) : -1 * SPEED * Math.cos(angulos[i]);
shObj.dy = !u ? SPEED * Math.sin(angulos[i]) : -1 * SPEED * Math.sin(angulos[i]);
_root.spark.duplicateMovieClip("spark" + i,10 + i,shObj);
}
}
}
if(borrar)
{
this.removeMovieClip();
borrar = false;
}
}